home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2006 May / PCWMAY06.iso / Software / Resources / Partition Logic 0.61 / partlogic-0.61.iso / system / headers / sys / linuxswap.h < prev    next >
Text File  |  2006-01-31  |  1KB  |  49 lines

  1. // 
  2. //  Visopsys
  3. //  Copyright (C) 1998-2006 J. Andrew McLaughlin
  4. //  
  5. //  This library is free software; you can redistribute it and/or modify it
  6. //  under the terms of the GNU Lesser General Public License as published by
  7. //  the Free Software Foundation; either version 2.1 of the License, or (at
  8. //  your option) any later version.
  9. //
  10. //  This library is distributed in the hope that it will be useful, but
  11. //  WITHOUT ANY WARRANTY; without even the implied warranty of
  12. //  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser
  13. //  General Public License for more details.
  14. //
  15. //  You should have received a copy of the GNU Lesser General Public License
  16. //  along with this library; if not, write to the Free Software Foundation,
  17. //  Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  18. //
  19. //  linux-swap.h
  20. //
  21.  
  22. // This file contains definitions and structures for using and manipulating
  23. // the Linux swap filesystem in Visopsys.
  24.  
  25. #if !defined(_LINUXSWAP_H)
  26.  
  27. typedef struct {
  28.   union  {
  29.     struct {
  30.       char reserved[MEMORY_PAGE_SIZE - 10];
  31.       char magic[10]; /* SWAP-SPACE or SWAPSPACE2 */
  32.       
  33.     } magic;
  34.     
  35.     struct {
  36.       char bootbits[1024];    /* Space for disklabel etc. */
  37.       int version;
  38.       unsigned lastPage;
  39.       unsigned numBadPages;
  40.       unsigned padding[125];
  41.       unsigned badPages[1];
  42.  
  43.     } info;
  44.   };
  45. } __attribute__((packed)) linuxSwapHeader;
  46.  
  47. #define _LINUXSWAP_H
  48. #endif
  49.